package com.yc.config;

import lombok.Data;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Component;

/**
 * <p>
 * RSA
 * <p>
 *
 * @author BAO
 * @since 2020/12/3 13:27
 */
@Data
@Component
public class RsaProperties {
    public static String publicKey;
    public static String privateKey;

    @Value("${rsa.public-key}")
    public void setPublicKey(String publicKey) {
        RsaProperties.publicKey = publicKey;
    }

    @Value("${rsa.private-key}")
    public void setPrivateKey(String privateKey) {
        RsaProperties.privateKey = privateKey;
    }
}
